package Engine;

import java.io.IOException;
import sun.misc.*;


public class Codec {

    public String encodeText(String normaltext) {
        return new BASE64Encoder().encode(normaltext.getBytes());
    }

    public String DecodeText(String decodedText) {        
        try {           
            return new String(new BASE64Decoder().decodeBuffer(decodedText));
        } catch (IOException e) {
        }
        return null;
    }
}
